<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<title>MiXiM: ConstMapping Class Reference</title>

<link href="tabs.css" rel="stylesheet" type="text/css"/>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
<link href="navtree.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="resize.js"></script>
<script type="text/javascript" src="navtree.js"></script>
<script type="text/javascript">
  $(document).ready(initResizable);
</script>


</head>
<body>
<div id="top"><!-- do not remove this div! -->


<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  
  
  <td style="padding-left: 0.5em;">
   <div id="projectname">MiXiM
   &#160;<span id="projectnumber">2.3</span>
   </div>
   
  </td>
  
  
  
 </tr>
 </tbody>
</table>
</div>

<!-- Generated by Doxygen 1.7.5.1 -->
  <div id="navrow1" class="tabs">
    <ul class="tablist">
      <li><a href="index.html"><span>Main&#160;Page</span></a></li>
      <li><a href="pages.html"><span>Related&#160;Pages</span></a></li>
      <li><a href="modules.html"><span>Modules</span></a></li>
      <li class="current"><a href="annotated.html"><span>Classes</span></a></li>
      <li><a href="files.html"><span>Files</span></a></li>
      <li><a href="dirs.html"><span>Directories</span></a></li>
    </ul>
  </div>
  <div id="navrow2" class="tabs2">
    <ul class="tablist">
      <li><a href="annotated.html"><span>Class&#160;List</span></a></li>
      <li><a href="classes.html"><span>Class&#160;Index</span></a></li>
      <li><a href="inherits.html"><span>Class&#160;Hierarchy</span></a></li>
      <li><a href="functions.html"><span>Class&#160;Members</span></a></li>
    </ul>
  </div>
</div>
<div id="side-nav" class="ui-resizable side-nav-resizable">
  <div id="nav-tree">
    <div id="nav-tree-contents">
    </div>
  </div>
  <div id="splitbar" style="-moz-user-select:none;" 
       class="ui-resizable-handle">
  </div>
</div>
<script type="text/javascript">
  initNavTree('a00058.html','');
</script>
<div id="doc-content">
<div class="header">
  <div class="summary">
<a href="#pub-types">Public Types</a> &#124;
<a href="#pub-methods">Public Member Functions</a> &#124;
<a href="#pro-attribs">Protected Attributes</a> &#124;
<a href="#pri-methods">Private Member Functions</a> &#124;
<a href="#friends">Friends</a>  </div>
  <div class="headertitle">
<div class="title">ConstMapping Class Reference<div class="ingroups"><a class="el" href="a00519.html">mapping - classes representing mathematical mappings</a></div></div>  </div>
</div>
<div class="contents">
<!-- doxytag: class="ConstMapping" -->
<p>Represents a not changeable mapping (mathematical function) from domain with at least the time to a Argument::mapped_type value.  
 <a href="a00058.html#details">More...</a></p>

<p><code>#include &lt;<a class="el" href="a00298_source.html">MappingBase.h</a>&gt;</code></p>
<div class="dynheader">
Inheritance diagram for ConstMapping:</div>
<div class="dyncontent">
<div class="center"><img src="a00664.png" border="0" usemap="#ConstMapping_inherit__map" alt="Inheritance graph"/></div>
<center><span class="legend">[<a target="top" href="graph_legend.html">legend</a>]</span></center></div>
<div class="dynheader">
Collaboration diagram for ConstMapping:</div>
<div class="dyncontent">
<div class="center"><img src="a00665.png" border="0" usemap="#ConstMapping_coll__map" alt="Collaboration graph"/></div>
<center><span class="legend">[<a target="top" href="graph_legend.html">legend</a>]</span></center></div>

<p><a href="a00666.html">List of all members.</a></p>
<table class="memberdecls">
<tr><td colspan="2"><h2><a name="pub-types"></a>
Public Types</h2></td></tr>
<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a5dac61c952f423e9a113ee90a4e0bdeb"></a><!-- doxytag: member="ConstMapping::argument_value_t" ref="a5dac61c952f423e9a113ee90a4e0bdeb" args="" -->
typedef Argument::mapped_type&#160;</td><td class="memItemRight" valign="bottom"><b>argument_value_t</b></td></tr>
<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a136fb6397efc9ba6a16235fa95339db9"></a><!-- doxytag: member="ConstMapping::argument_value_cref_t" ref="a136fb6397efc9ba6a16235fa95339db9" args="" -->
typedef Argument::mapped_type_cref&#160;</td><td class="memItemRight" valign="bottom"><b>argument_value_cref_t</b></td></tr>
<tr><td colspan="2"><h2><a name="pub-methods"></a>
Public Member Functions</h2></td></tr>
<tr><td class="memItemLeft" align="right" valign="top"><a class="el" href="a00058.html">ConstMapping</a> &amp;&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="a00058.html#a28a66ff19a5046d773d6f0c49f12353f">operator=</a> (const <a class="el" href="a00058.html">ConstMapping</a> &amp;copy)</td></tr>
<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">ConstMapping assignment operator.  <a href="#a28a66ff19a5046d773d6f0c49f12353f"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="a00058.html#a473df8fa0aa441ca1adb356b17b1f59f">swap</a> (<a class="el" href="a00058.html">ConstMapping</a> &amp;s)</td></tr>
<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">Swaps data with another ConstMapping.  <a href="#a473df8fa0aa441ca1adb356b17b1f59f"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a7cfc5de32a0d03abfeb9b77fdcf7a413"></a><!-- doxytag: member="ConstMapping::ConstMapping" ref="a7cfc5de32a0d03abfeb9b77fdcf7a413" args="()" -->
&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="a00058.html#a7cfc5de32a0d03abfeb9b77fdcf7a413">ConstMapping</a> ()</td></tr>
<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">Initializes the <a class="el" href="a00058.html" title="Represents a not changeable mapping (mathematical function) from domain with at least the time to a A...">ConstMapping</a> with a the time dimension as domain. <br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a9719bb482f7872e7cd205b62e718d1c2"></a><!-- doxytag: member="ConstMapping::ConstMapping" ref="a9719bb482f7872e7cd205b62e718d1c2" args="(const ConstMapping &amp;o)" -->
&#160;</td><td class="memItemRight" valign="bottom"><b>ConstMapping</b> (const <a class="el" href="a00058.html">ConstMapping</a> &amp;o)</td></tr>
<tr><td class="memItemLeft" align="right" valign="top">&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="a00058.html#a4e057daa0a3726cafa70bac0e5393b26">ConstMapping</a> (const <a class="el" href="a00086.html">DimensionSet</a> &amp;dimSet)</td></tr>
<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">Initializes the <a class="el" href="a00058.html" title="Represents a not changeable mapping (mathematical function) from domain with at least the time to a A...">ConstMapping</a> with the passed <a class="el" href="a00086.html" title="Represents a set of dimensions which is used to define over which dimensions a mapping is defined (th...">DimensionSet</a> as Domain.  <a href="#a4e057daa0a3726cafa70bac0e5393b26"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">virtual argument_value_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="a00058.html#afabbd15bb8f50e45901f99633d0a47c9">getValue</a> (const <a class="el" href="a00013.html">Argument</a> &amp;pos) const =0</td></tr>
<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">Returns the value of this <a class="el" href="a00136.html" title="Represents a changeable mapping (mathematical function) from at least time to Argument::mapped_type.">Mapping</a> at the position specified by the passed <a class="el" href="a00013.html" title="Defines an argument for a mapping.">Argument</a>.  <a href="#afabbd15bb8f50e45901f99633d0a47c9"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">virtual <a class="el" href="a00059.html">ConstMappingIterator</a> *&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="a00058.html#a5ff3a15fe6d536fa7a26a3fe1ff1b274">createConstIterator</a> () const =0</td></tr>
<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">Returns a pointer of a new Iterator which is able to iterate over this <a class="el" href="a00136.html" title="Represents a changeable mapping (mathematical function) from at least time to Argument::mapped_type.">Mapping</a>.  <a href="#a5ff3a15fe6d536fa7a26a3fe1ff1b274"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">virtual <a class="el" href="a00059.html">ConstMappingIterator</a> *&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="a00058.html#a951552e2e7f48717ed79d540af538d73">createConstIterator</a> (const <a class="el" href="a00013.html">Argument</a> &amp;pos) const =0</td></tr>
<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">Returns a pointer of a new Iterator which is able to iterate over the function. The iterator starts at the passed position.  <a href="#a951552e2e7f48717ed79d540af538d73"></a><br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a741e083fb18412a3d9cde7eac3dced10"></a><!-- doxytag: member="ConstMapping::constClone" ref="a741e083fb18412a3d9cde7eac3dced10" args="() const =0" -->
virtual <a class="el" href="a00058.html">ConstMapping</a> *&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="a00058.html#a741e083fb18412a3d9cde7eac3dced10">constClone</a> () const =0</td></tr>
<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">returns a deep copy of this mapping instance. <br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a9b0ba6e7aaa108549dcd71069fefe199"></a><!-- doxytag: member="ConstMapping::operator[]" ref="a9b0ba6e7aaa108549dcd71069fefe199" args="(const Argument &amp;pos) const " -->
argument_value_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="a00058.html#a9b0ba6e7aaa108549dcd71069fefe199">operator[]</a> (const <a class="el" href="a00013.html">Argument</a> &amp;pos) const </td></tr>
<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">Returns the value of this <a class="el" href="a00136.html" title="Represents a changeable mapping (mathematical function) from at least time to Argument::mapped_type.">Mapping</a> at the position specified by the passed <a class="el" href="a00013.html" title="Defines an argument for a mapping.">Argument</a>. <br/></td></tr>
<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="acc1559cf5741bec3aa6422e94c5b9cce"></a><!-- doxytag: member="ConstMapping::getDimensionSet" ref="acc1559cf5741bec3aa6422e94c5b9cce" args="() const " -->
const <a class="el" href="a00086.html">DimensionSet</a> &amp;&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="a00058.html#acc1559cf5741bec3aa6422e94c5b9cce">getDimensionSet</a> () const </td></tr>
<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">Returns this Mappings domain as <a class="el" href="a00086.html" title="Represents a set of dimensions which is used to define over which dimensions a mapping is defined (th...">DimensionSet</a>. <br/></td></tr>
<tr><td class="memTemplParams" colspan="2">template&lt;class stream &gt; </td></tr>
<tr><td class="memTemplItemLeft" align="right" valign="top">stream &amp;&#160;</td><td class="memTemplItemRight" valign="bottom"><a class="el" href="a00058.html#a526e8d5b948e9b2ce9d729e66b162e13">print</a> (stream &amp;out, argument_value_cref_t lTimeScale=argument_value_t(1000), argument_value_cref_t lLeftColScale=<a class="el" href="a00013.html#a657d962a1b965814e6b2eecb07f03e80">Argument::MappedOne</a>, const std::string &amp;sTableHead=std::string(&quot;o\\ms&quot;), const <a class="el" href="a00085.html">Dimension</a> *const pOnlyDim=NULL) const </td></tr>
<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">Prints the <a class="el" href="a00136.html" title="Represents a changeable mapping (mathematical function) from at least time to Argument::mapped_type.">Mapping</a> to an output stream.  <a href="#a526e8d5b948e9b2ce9d729e66b162e13"></a><br/></td></tr>
<tr><td colspan="2"><h2><a name="pro-attribs"></a>
Protected Attributes</h2></td></tr>
<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a009539b72014b7bed96402a5c244fca5"></a><!-- doxytag: member="ConstMapping::dimensions" ref="a009539b72014b7bed96402a5c244fca5" args="" -->
<a class="el" href="a00086.html">DimensionSet</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="a00058.html#a009539b72014b7bed96402a5c244fca5">dimensions</a></td></tr>
<tr><td class="mdescLeft">&#160;</td><td class="mdescRight">The dimensions of this mappings domain. <br/></td></tr>
<tr><td colspan="2"><h2><a name="pri-methods"></a>
Private Member Functions</h2></td></tr>
<tr><td class="memTemplParams" colspan="2"><a class="anchor" id="aedc3078350fcad21ac9c02d6f7245ad2"></a><!-- doxytag: member="ConstMapping::toString" ref="aedc3078350fcad21ac9c02d6f7245ad2" args="(T v, unsigned int length) const " -->
template&lt;class T &gt; </td></tr>
<tr><td class="memTemplItemLeft" align="right" valign="top">std::string&#160;</td><td class="memTemplItemRight" valign="bottom"><b>toString</b> (T v, unsigned int length) const </td></tr>
<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a3fcd3636b4a21f86cccb0d56373aa5a8"></a><!-- doxytag: member="ConstMapping::toString" ref="a3fcd3636b4a21f86cccb0d56373aa5a8" args="(simtime_t_cref v, unsigned int length) const " -->
std::string&#160;</td><td class="memItemRight" valign="bottom"><b>toString</b> (simtime_t_cref v, unsigned int length) const </td></tr>
<tr><td colspan="2"><h2><a name="friends"></a>
Friends</h2></td></tr>
<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="ac01413f3aae147d0c6b9cfcf411b610f"></a><!-- doxytag: member="ConstMapping::operator&lt;&lt;" ref="ac01413f3aae147d0c6b9cfcf411b610f" args="(std::ostream &amp;out, const ConstMapping &amp;rMapToPrint)" -->
std::ostream &amp;&#160;</td><td class="memItemRight" valign="bottom"><b>operator&lt;&lt;</b> (std::ostream &amp;out, const <a class="el" href="a00058.html">ConstMapping</a> &amp;rMapToPrint)</td></tr>
</table>
<hr/><a name="details" id="details"></a><h2>Detailed Description</h2>
<div class="textblock"><p>Represents a not changeable mapping (mathematical function) from domain with at least the time to a Argument::mapped_type value. </p>
<p>This class is an interface which describes a mapping (math.) from a arbitrary dimensional domain (represented by a <a class="el" href="a00086.html" title="Represents a set of dimensions which is used to define over which dimensions a mapping is defined (th...">DimensionSet</a>) to a Argument::mapped_type value.</p>
<dl class="author"><dt><b>Author:</b></dt><dd>Karl Wessel </dd></dl>
</div><hr/><h2>Constructor &amp; Destructor Documentation</h2>
<a class="anchor" id="a4e057daa0a3726cafa70bac0e5393b26"></a><!-- doxytag: member="ConstMapping::ConstMapping" ref="a4e057daa0a3726cafa70bac0e5393b26" args="(const DimensionSet &amp;dimSet)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">ConstMapping::ConstMapping </td>
          <td>(</td>
          <td class="paramtype">const <a class="el" href="a00086.html">DimensionSet</a> &amp;&#160;</td>
          <td class="paramname"><em>dimSet</em></td><td>)</td>
          <td><code> [inline]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Initializes the <a class="el" href="a00058.html" title="Represents a not changeable mapping (mathematical function) from domain with at least the time to a A...">ConstMapping</a> with the passed <a class="el" href="a00086.html" title="Represents a set of dimensions which is used to define over which dimensions a mapping is defined (th...">DimensionSet</a> as Domain. </p>
<p>The passed <a class="el" href="a00086.html" title="Represents a set of dimensions which is used to define over which dimensions a mapping is defined (th...">DimensionSet</a> has to contain the time dimension! </p>

<p>References <a class="el" href="a00086.html#a015cb6fa6c77b26b8c7b1e65827b8342">DimensionSet::hasDimension()</a>, and <a class="el" href="a00085.html#a16cb1f186dd3f48d33a4aebe948001d7">Dimension::time</a>.</p>
<div class="fragment"><pre class="fragment">                                          :
    <a class="code" href="a00058.html#a009539b72014b7bed96402a5c244fca5" title="The dimensions of this mappings domain.">dimensions</a>(dimSet) {

    assert(dimSet.<a class="code" href="a00086.html#a015cb6fa6c77b26b8c7b1e65827b8342" title="Returns true if the passed Dimension is inside this DimensionSet.">hasDimension</a>(<a class="code" href="a00085.html#a16cb1f186dd3f48d33a4aebe948001d7" title="Shortcut to the time Dimension, same as &#39;Dimension(&quot;time&quot;)&#39;, but spares the parsing of a string...">Dimension::time</a>));
  }
</pre></div>
</div>
</div>
<hr/><h2>Member Function Documentation</h2>
<a class="anchor" id="a5ff3a15fe6d536fa7a26a3fe1ff1b274"></a><!-- doxytag: member="ConstMapping::createConstIterator" ref="a5ff3a15fe6d536fa7a26a3fe1ff1b274" args="() const =0" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">virtual <a class="el" href="a00059.html">ConstMappingIterator</a>* ConstMapping::createConstIterator </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td> const<code> [pure virtual]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Returns a pointer of a new Iterator which is able to iterate over this <a class="el" href="a00136.html" title="Represents a changeable mapping (mathematical function) from at least time to Argument::mapped_type.">Mapping</a>. </p>
<p>See class ConstIterator for details. </p>

<p>Implemented in <a class="el" href="a00049.html#a417cebabd88daa682ea0f3cae877eae2">ConcatConstMapping&lt; Operator &gt;</a>, <a class="el" href="a00194.html#a70d0d044f36428965b77233bbf4c698b">SimpleConstMapping</a>, <a class="el" href="a00136.html#acdf62aed4b8a469e63c036e75567c2e3">Mapping</a>, <a class="el" href="a00061.html#a6a2c09d666b9e986798d0be48add4cdd">ConstMappingWrapper</a>, and <a class="el" href="a00189.html#a0c4471fe51b34fab8f93b644326c1862">RSAMMapping</a>.</p>

<p>Referenced by <a class="el" href="a00203.html#ae38586c5255f37cfe67aa1bdec283dde">SNRThresholdDecider::canAnswerCSR()</a>, <a class="el" href="a00049.html#a417cebabd88daa682ea0f3cae877eae2">ConcatConstMapping&lt; Operator &gt;::createConstIterator()</a>, <a class="el" href="a00074.html#a0543e527dd0cad7b247b0fd0d55e038a">Decider802154Narrow::createResult()</a>, <a class="el" href="a00222.html#a3a27ac6615499a86832230bfaafabb7a">UWBIRIEEE802154APathlossModel::filterSignal()</a>, <a class="el" href="a00138.html#afbe1a1e1d2becd66d2c0d5a8ac42b478">MappingUtils::findMax()</a>, <a class="el" href="a00138.html#a5d9c4e3dcaddccfa65f21212d0fee2cf">MappingUtils::findMin()</a>, and <a class="el" href="a00058.html#a526e8d5b948e9b2ce9d729e66b162e13">print()</a>.</p>

</div>
</div>
<a class="anchor" id="a951552e2e7f48717ed79d540af538d73"></a><!-- doxytag: member="ConstMapping::createConstIterator" ref="a951552e2e7f48717ed79d540af538d73" args="(const Argument &amp;pos) const =0" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">virtual <a class="el" href="a00059.html">ConstMappingIterator</a>* ConstMapping::createConstIterator </td>
          <td>(</td>
          <td class="paramtype">const <a class="el" href="a00013.html">Argument</a> &amp;&#160;</td>
          <td class="paramname"><em>pos</em></td><td>)</td>
          <td> const<code> [pure virtual]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Returns a pointer of a new Iterator which is able to iterate over the function. The iterator starts at the passed position. </p>
<p>See class ConstIterator for details. </p>

<p>Implemented in <a class="el" href="a00049.html#a738035f30d7c365838469aa3eb7e7381">ConcatConstMapping&lt; Operator &gt;</a>, <a class="el" href="a00194.html#ab0dfc0c3ba9ba222176b29d88a4e6578">SimpleConstMapping</a>, <a class="el" href="a00136.html#aa659ff5ecd1020261cbd39d136ea1f57">Mapping</a>, <a class="el" href="a00061.html#a648971050f302ee9afd31ebd51d54698">ConstMappingWrapper</a>, and <a class="el" href="a00189.html#a79e3de9b0f3220b01dd28346e51ae019">RSAMMapping</a>.</p>

</div>
</div>
<a class="anchor" id="afabbd15bb8f50e45901f99633d0a47c9"></a><!-- doxytag: member="ConstMapping::getValue" ref="afabbd15bb8f50e45901f99633d0a47c9" args="(const Argument &amp;pos) const =0" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">virtual argument_value_t ConstMapping::getValue </td>
          <td>(</td>
          <td class="paramtype">const <a class="el" href="a00013.html">Argument</a> &amp;&#160;</td>
          <td class="paramname"><em>pos</em></td><td>)</td>
          <td> const<code> [pure virtual]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Returns the value of this <a class="el" href="a00136.html" title="Represents a changeable mapping (mathematical function) from at least time to Argument::mapped_type.">Mapping</a> at the position specified by the passed <a class="el" href="a00013.html" title="Defines an argument for a mapping.">Argument</a>. </p>
<p>The complexity of this method depends on the actual implementation. </p>

<p>Implemented in <a class="el" href="a00049.html#a28448679df346f8baf0f889bc0ab522a">ConcatConstMapping&lt; Operator &gt;</a>, <a class="el" href="a00194.html#aeb10c744b8f4c6df092332b6228e209e">SimpleConstMapping</a>, <a class="el" href="a00148.html#a524f27f6b8f01dc973dbe54f0f9c5ed2">MultiDimMapping&lt; Interpolator &gt;</a>, <a class="el" href="a00148.html#a524f27f6b8f01dc973dbe54f0f9c5ed2">MultiDimMapping&lt; Linear &gt;</a>, <a class="el" href="a00061.html#a6706d0676194d24aa60059d93c8cbc44">ConstMappingWrapper</a>, <a class="el" href="a00055.html#a64ad8ca116f9a3f0ea575954f43a6706">ConstantSimpleConstMapping</a>, <a class="el" href="a00189.html#adfde2753ba641cbdafbd95fc914034e6">RSAMMapping</a>, <a class="el" href="a00120.html#a8711b30cf4ab9148864caa503240adb4">LinearIntplMapping</a>, <a class="el" href="a00212.html#a4f46930630d6c6a79b34211992840731">TimeMapping&lt; Interpolator &gt;</a>, <a class="el" href="a00212.html#a4f46930630d6c6a79b34211992840731">TimeMapping&lt; Linear &gt;</a>, <a class="el" href="a00115.html#a23e8978d7aab4509f846ac6a8044de19">JakesFadingMapping</a>, <a class="el" href="a00198.html#aa263547a6e528cc1acf88fc496510e40">SimplePathlossConstMapping</a>, and <a class="el" href="a00200.html#aa7f481ebc2ec51c38a98af9595fb00cc">SimpleTimeConstMapping</a>.</p>

<p>Referenced by <a class="el" href="a00074.html#a0543e527dd0cad7b247b0fd0d55e038a">Decider802154Narrow::createResult()</a>, <a class="el" href="a00020.html#a5e45eb03d1a7f3653385181236714f21">BaseDecider::getNextSignalHandleTime()</a>, and <a class="el" href="a00049.html#a28448679df346f8baf0f889bc0ab522a">ConcatConstMapping&lt; Operator &gt;::getValue()</a>.</p>

</div>
</div>
<a class="anchor" id="a28a66ff19a5046d773d6f0c49f12353f"></a><!-- doxytag: member="ConstMapping::operator=" ref="a28a66ff19a5046d773d6f0c49f12353f" args="(const ConstMapping &amp;copy)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="a00058.html">ConstMapping</a>&amp; ConstMapping::operator= </td>
          <td>(</td>
          <td class="paramtype">const <a class="el" href="a00058.html">ConstMapping</a> &amp;&#160;</td>
          <td class="paramname"><em>copy</em></td><td>)</td>
          <td><code> [inline]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>ConstMapping assignment operator. </p>
<dl><dt><b>Parameters:</b></dt><dd>
  <table class="params">
    <tr><td class="paramname">copy</td><td>A ConstMapping of identical element and allocator types.</td></tr>
  </table>
  </dd>
</dl>
<p>All the elements of <em>copy</em> are copied. </p>

<p>References <a class="el" href="a00058.html#a009539b72014b7bed96402a5c244fca5">dimensions</a>.</p>

<p>Referenced by <a class="el" href="a00136.html#a973f72ed384d6cead14f23d20bafee93">Mapping::operator=()</a>, and <a class="el" href="a00194.html#aa49498d175e63415d1b16656ffe2e28b">SimpleConstMapping::operator=()</a>.</p>
<div class="fragment"><pre class="fragment">  {
    <a class="code" href="a00058.html#a009539b72014b7bed96402a5c244fca5" title="The dimensions of this mappings domain.">dimensions</a> = copy.<a class="code" href="a00058.html#a009539b72014b7bed96402a5c244fca5" title="The dimensions of this mappings domain.">dimensions</a>;
    <span class="keywordflow">return</span> *<span class="keyword">this</span>;
  }
</pre></div>
</div>
</div>
<a class="anchor" id="a526e8d5b948e9b2ce9d729e66b162e13"></a><!-- doxytag: member="ConstMapping::print" ref="a526e8d5b948e9b2ce9d729e66b162e13" args="(stream &amp;out, argument_value_cref_t lTimeScale=argument_value_t(1000), argument_value_cref_t lLeftColScale=Argument::MappedOne, const std::string &amp;sTableHead=std::string(&quot;o\\ms&quot;), const Dimension *const pOnlyDim=NULL) const " -->
<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;class stream &gt; </div>
      <table class="memname">
        <tr>
          <td class="memname">stream&amp; ConstMapping::print </td>
          <td>(</td>
          <td class="paramtype">stream &amp;&#160;</td>
          <td class="paramname"><em>out</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">argument_value_cref_t&#160;</td>
          <td class="paramname"><em>lTimeScale</em> = <code>argument_value_t(1000)</code>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">argument_value_cref_t&#160;</td>
          <td class="paramname"><em>lLeftColScale</em> = <code><a class="el" href="a00013.html#a657d962a1b965814e6b2eecb07f03e80">Argument::MappedOne</a></code>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const std::string &amp;&#160;</td>
          <td class="paramname"><em>sTableHead</em> = <code>std::string(&quot;o\\ms&quot;)</code>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const <a class="el" href="a00085.html">Dimension</a> *const&#160;</td>
          <td class="paramname"><em>pOnlyDim</em> = <code>NULL</code>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td> const<code> [inline]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Prints the <a class="el" href="a00136.html" title="Represents a changeable mapping (mathematical function) from at least time to Argument::mapped_type.">Mapping</a> to an output stream. </p>
<dl><dt><b>Parameters:</b></dt><dd>
  <table class="params">
    <tr><td class="paramname">out</td><td>The output stream to print. </td></tr>
    <tr><td class="paramname">lTimeScale</td><td>The scaling factor for the time header values (default 1000). </td></tr>
    <tr><td class="paramname">lLeftColScale</td><td>The scaling factor for the left column values (default 1, unscaled). </td></tr>
    <tr><td class="paramname">sTableHead</td><td>The header string for the left column (default: "o\\ms"). </td></tr>
    <tr><td class="paramname">pOnlyDim</td><td>Pointer to a specific dimension which should be used as the left column (should not be the <a class="el" href="a00085.html#a16cb1f186dd3f48d33a4aebe948001d7" title="Shortcut to the time Dimension, same as &#39;Dimension(&quot;time&quot;)&#39;, but spares the parsing of a string...">Dimension::time</a>). </td></tr>
  </table>
  </dd>
</dl>

<p>References <a class="el" href="a00013.html#af0e836fd4aaecc1461b994e21f66ddc3">Argument::begin()</a>, <a class="el" href="a00058.html#a5ff3a15fe6d536fa7a26a3fe1ff1b274">createConstIterator()</a>, <a class="el" href="a00013.html#aeeb6730c20ae8a8d6c9606f2e03cc1da">Argument::end()</a>, <a class="el" href="a00013.html#ae4b61830a991f8911978c30a67dd2da6">Argument::find()</a>, <a class="el" href="a00013.html#a137a911de0281cbb519fe13727aa0813">Argument::getArgValue()</a>, <a class="el" href="a00058.html#acc1559cf5741bec3aa6422e94c5b9cce">getDimensionSet()</a>, <a class="el" href="a00059.html#a047e853613d5a19ff34526d0cff8fcf9">ConstMappingIterator::getPosition()</a>, <a class="el" href="a00013.html#a2ecb3b041b5b8721d6767531e4ac792a">Argument::getTime()</a>, <a class="el" href="a00059.html#ad4419c259e747867f003d07d62d4259f">ConstMappingIterator::getValue()</a>, <a class="el" href="a00059.html#ad4bac7233c154b7086c6124d2e21be49">ConstMappingIterator::hasNext()</a>, <a class="el" href="a00059.html#a4a6348a453418da95978e570fec046fc">ConstMappingIterator::inRange()</a>, <a class="el" href="a00059.html#afdafa6870cd19b3d35674a7bc777585d">ConstMappingIterator::next()</a>, <a class="el" href="a00013.html#a27bd7000e865670a673039233424d2ab">Argument::setArgValue()</a>, <a class="el" href="a00013.html#a8087982f050bdc61d787b128ca9ac8f9">Argument::setTime()</a>, <a class="el" href="a00086.html#a0bf532a8e4cbf151337d24b7246790a9">DimensionSet::size()</a>, and <a class="el" href="a00085.html#a16cb1f186dd3f48d33a4aebe948001d7">Dimension::time</a>.</p>

<p>Referenced by <a class="el" href="a00209.html#a4d46b0c578c9e817ea8084f53fc0e8e4">ThresholdDecider::printMapping()</a>.</p>
<div class="fragment"><pre class="fragment">                                                                   {
    <span class="keyword">const</span> <a class="code" href="a00058.html" title="Represents a not changeable mapping (mathematical function) from domain with at least the time to a A...">ConstMapping</a>&amp;      m = *<span class="keyword">this</span>;
    DimensionSet::value_type otherDim;
    <span class="keyword">const</span> <a class="code" href="a00086.html" title="Represents a set of dimensions which is used to define over which dimensions a mapping is defined (th...">DimensionSet</a>&amp;      dims = m.<a class="code" href="a00058.html#acc1559cf5741bec3aa6422e94c5b9cce" title="Returns this Mappings domain as DimensionSet.">getDimensionSet</a>();
    <span class="keywordtype">bool</span>                     bOnlyDimFound = <span class="keyword">false</span>;

    <span class="keyword">using</span> std::operator&lt;&lt;;

    std::stringstream            osDimHead(std::stringstream::out);
    <span class="keywordtype">bool</span>                         bTimeIsIn = <span class="keyword">false</span>;
    <span class="keyword">const</span> DimensionSet::iterator dimsEnd   = dims.end();
    <span class="keywordflow">for</span>(DimensionSet::iterator it = dims.begin(); it != dimsEnd; ++it) {
      <span class="keywordflow">if</span>(*it != <a class="code" href="a00085.html#a16cb1f186dd3f48d33a4aebe948001d7" title="Shortcut to the time Dimension, same as &#39;Dimension(&quot;time&quot;)&#39;, but spares the parsing of a string...">Dimension::time</a>) {
        <span class="keywordflow">if</span> (pOnlyDim &amp;&amp; *it == *pOnlyDim) {
          otherDim      = *it;
          bOnlyDimFound = pOnlyDim != NULL;
        }
        <span class="keywordflow">else</span> <span class="keywordflow">if</span> (!pOnlyDim) {
          otherDim      = *it;
        }
        <span class="keywordflow">if</span> (!osDimHead.str().empty())
          osDimHead &lt;&lt; <span class="stringliteral">&quot;, &quot;</span>;
        osDimHead &lt;&lt; *it;
      }
      <span class="keywordflow">else</span>
        bTimeIsIn = <span class="keyword">true</span>;
    }
    <span class="keywordflow">if</span> (bTimeIsIn || !osDimHead.str().empty()) {
      out &lt;&lt; <span class="stringliteral">&quot;Mapping domain: &quot;</span>;
      <span class="keywordflow">if</span> (bTimeIsIn) {
        out &lt;&lt; <span class="stringliteral">&quot;time&quot;</span>;
        <span class="keywordflow">if</span> (!osDimHead.str().empty())
          out &lt;&lt; <span class="stringliteral">&quot;, &quot;</span>;
      }
      out &lt;&lt; osDimHead.str() &lt;&lt; endl;
    }

    <a class="code" href="a00059.html" title="Defines an const iterator for a ConstMapping which is able to iterate over the Mapping.">ConstMappingIterator</a>* it = m.<a class="code" href="a00058.html#a5ff3a15fe6d536fa7a26a3fe1ff1b274" title="Returns a pointer of a new Iterator which is able to iterate over this Mapping.">createConstIterator</a>();

    <span class="keywordflow">if</span>(!it-&gt;<a class="code" href="a00059.html#a4a6348a453418da95978e570fec046fc" title="Returns true if the current position of the iterator is in range of the function.">inRange</a>()) {
      out &lt;&lt; <span class="stringliteral">&quot;Mapping is empty.&quot;</span> &lt;&lt; endl;
      <span class="keywordflow">return</span> out;
    }

    <a class="code" href="a00013.html" title="Defines an argument for a mapping.">Argument</a> min = it-&gt;<a class="code" href="a00059.html#a047e853613d5a19ff34526d0cff8fcf9" title="Returns the current position of the iterator.">getPosition</a>();
    <a class="code" href="a00013.html" title="Defines an argument for a mapping.">Argument</a> max = it-&gt;<a class="code" href="a00059.html#a047e853613d5a19ff34526d0cff8fcf9" title="Returns the current position of the iterator.">getPosition</a>();

    <span class="keyword">typedef</span> std::set&lt;simtime_t&gt;         t_time_container_type;
    <span class="keyword">typedef</span> std::set&lt;argument_value_t&gt;  t_value_container_type;

    t_time_container_type  timePositions;
    t_value_container_type otherPositions;
    std::size_t            iMaxHeaderItemLen = m.toString(it-&gt;<a class="code" href="a00059.html#a047e853613d5a19ff34526d0cff8fcf9" title="Returns the current position of the iterator.">getPosition</a>().<a class="code" href="a00013.html#a2ecb3b041b5b8721d6767531e4ac792a" title="Returns the time value of this argument.">getTime</a>() * lTimeScale, 2).length();
    std::size_t            iMaxLeftItemLen   = 5 &gt; sTableHead.length() ? 5 : sTableHead.length();
    <span class="keyword">const</span> <span class="keywordtype">bool</span>             bIs2Dim           = dims.<a class="code" href="a00086.html#a0bf532a8e4cbf151337d24b7246790a9" title="Returns the size of the DimensionSet.">size</a>() == 2;

    <span class="keywordflow">if</span> (bIs2Dim &amp;&amp; bOnlyDimFound)
      bOnlyDimFound = <span class="keyword">false</span>; <span class="comment">// we have only the time and the requested dimension (fallback to normal case)</span>
    timePositions.insert(it-&gt;<a class="code" href="a00059.html#a047e853613d5a19ff34526d0cff8fcf9" title="Returns the current position of the iterator.">getPosition</a>().<a class="code" href="a00013.html#a2ecb3b041b5b8721d6767531e4ac792a" title="Returns the time value of this argument.">getTime</a>());
    <span class="keywordflow">if</span>(bIs2Dim || bOnlyDimFound) {
      <a class="code" href="a00013.html#a521abc97d737e8c77742dcc9f4b21022" title="Const-iterator type for this set.">Argument::const_iterator</a> posValIt;
      <span class="keywordflow">if</span> (bOnlyDimFound &amp;&amp; (posValIt = it-&gt;<a class="code" href="a00059.html#a047e853613d5a19ff34526d0cff8fcf9" title="Returns the current position of the iterator.">getPosition</a>().<a class="code" href="a00013.html#ae4b61830a991f8911978c30a67dd2da6" title="Returns an iterator to the Argument value for the passed Dimension.">find</a>(otherDim)) != it-&gt;<a class="code" href="a00059.html#a047e853613d5a19ff34526d0cff8fcf9" title="Returns the current position of the iterator.">getPosition</a>().<a class="code" href="a00013.html#aeeb6730c20ae8a8d6c9606f2e03cc1da" title="Returns an iterator to the value behind the last argument value.">end</a>()) {
        otherPositions.insert(it-&gt;<a class="code" href="a00059.html#a047e853613d5a19ff34526d0cff8fcf9" title="Returns the current position of the iterator.">getPosition</a>().<a class="code" href="a00013.html#a137a911de0281cbb519fe13727aa0813" title="Returns the value for the specified dimension.">getArgValue</a>(otherDim));
        iMaxLeftItemLen = std::max(iMaxLeftItemLen, m.toString(posValIt-&gt;second*lLeftColScale, 2).length());
      }
      <span class="keywordflow">else</span> <span class="keywordflow">if</span> (!bOnlyDimFound) {
        otherPositions.insert(it-&gt;<a class="code" href="a00059.html#a047e853613d5a19ff34526d0cff8fcf9" title="Returns the current position of the iterator.">getPosition</a>().<a class="code" href="a00013.html#af0e836fd4aaecc1461b994e21f66ddc3" title="Returns an iterator to the first argument value in this Argument.">begin</a>()-&gt;second);
        iMaxLeftItemLen = std::max(iMaxLeftItemLen, m.toString(it-&gt;<a class="code" href="a00059.html#a047e853613d5a19ff34526d0cff8fcf9" title="Returns the current position of the iterator.">getPosition</a>().<a class="code" href="a00013.html#af0e836fd4aaecc1461b994e21f66ddc3" title="Returns an iterator to the first argument value in this Argument.">begin</a>()-&gt;second*lLeftColScale, 2).length());
      }
    }

    <span class="keywordflow">while</span>(it-&gt;<a class="code" href="a00059.html#ad4bac7233c154b7086c6124d2e21be49" title="Returns true if the iterator has a next value it can iterate to on a call to &quot;next()&quot;.">hasNext</a>()) {
      it-&gt;<a class="code" href="a00059.html#afdafa6870cd19b3d35674a7bc777585d" title="Iterates to the next position of the Mapping.">next</a>();
      <span class="keyword">const</span> <a class="code" href="a00013.html" title="Defines an argument for a mapping.">Argument</a>&amp;                pos         = it-&gt;<a class="code" href="a00059.html#a047e853613d5a19ff34526d0cff8fcf9" title="Returns the current position of the iterator.">getPosition</a>();
      <span class="keyword">const</span> <a class="code" href="a00013.html#a521abc97d737e8c77742dcc9f4b21022" title="Const-iterator type for this set.">Argument::const_iterator</a> posValItEnd = pos.<a class="code" href="a00013.html#aeeb6730c20ae8a8d6c9606f2e03cc1da" title="Returns an iterator to the value behind the last argument value.">end</a>();
      <a class="code" href="a00013.html#a521abc97d737e8c77742dcc9f4b21022" title="Const-iterator type for this set.">Argument::const_iterator</a>       posValIt;

      min.<a class="code" href="a00013.html#a8087982f050bdc61d787b128ca9ac8f9" title="Changes the time value of this argument.">setTime</a>(std::min(min.<a class="code" href="a00013.html#a2ecb3b041b5b8721d6767531e4ac792a" title="Returns the time value of this argument.">getTime</a>(), pos.<a class="code" href="a00013.html#a2ecb3b041b5b8721d6767531e4ac792a" title="Returns the time value of this argument.">getTime</a>()));
      max.<a class="code" href="a00013.html#a8087982f050bdc61d787b128ca9ac8f9" title="Changes the time value of this argument.">setTime</a>(std::max(max.<a class="code" href="a00013.html#a2ecb3b041b5b8721d6767531e4ac792a" title="Returns the time value of this argument.">getTime</a>(), pos.<a class="code" href="a00013.html#a2ecb3b041b5b8721d6767531e4ac792a" title="Returns the time value of this argument.">getTime</a>()));

      timePositions.insert(pos.<a class="code" href="a00013.html#a2ecb3b041b5b8721d6767531e4ac792a" title="Returns the time value of this argument.">getTime</a>());

      iMaxHeaderItemLen = std::max(iMaxHeaderItemLen, m.toString(pos.<a class="code" href="a00013.html#a2ecb3b041b5b8721d6767531e4ac792a" title="Returns the time value of this argument.">getTime</a>() * lTimeScale, 2).length());

      <span class="keywordflow">if</span> (bOnlyDimFound &amp;&amp; (posValIt = pos.<a class="code" href="a00013.html#ae4b61830a991f8911978c30a67dd2da6" title="Returns an iterator to the Argument value for the passed Dimension.">find</a>(otherDim)) != posValItEnd) {
        iMaxLeftItemLen = std::max(iMaxLeftItemLen, m.toString(posValIt-&gt;second*lLeftColScale, 2).length());
      }
      <span class="keywordflow">for</span>(<a class="code" href="a00013.html#a521abc97d737e8c77742dcc9f4b21022" title="Const-iterator type for this set.">Argument::const_iterator</a> itA = pos.<a class="code" href="a00013.html#af0e836fd4aaecc1461b994e21f66ddc3" title="Returns an iterator to the first argument value in this Argument.">begin</a>(); itA != posValItEnd; ++itA) {
        <span class="keywordflow">if</span>(bIs2Dim || bOnlyDimFound) {
          <span class="keywordflow">if</span> (!bOnlyDimFound || itA-&gt;first == otherDim) {
            otherPositions.insert(itA-&gt;second);
            iMaxLeftItemLen = std::max(iMaxLeftItemLen, m.toString(itA-&gt;second*lLeftColScale, 2).length());
          }
        }
        min.<a class="code" href="a00013.html#a27bd7000e865670a673039233424d2ab" title="Changes the value for the specified dimension.">setArgValue</a>(itA-&gt;first, std::min(min.<a class="code" href="a00013.html#a137a911de0281cbb519fe13727aa0813" title="Returns the value for the specified dimension.">getArgValue</a>(itA-&gt;first), itA-&gt;second));
        max.<a class="code" href="a00013.html#a27bd7000e865670a673039233424d2ab" title="Changes the value for the specified dimension.">setArgValue</a>(itA-&gt;first, std::max(max.<a class="code" href="a00013.html#a137a911de0281cbb519fe13727aa0813" title="Returns the value for the specified dimension.">getArgValue</a>(itA-&gt;first), itA-&gt;second));
      }
    }
    <span class="keyword">delete</span> it;

    <span class="keywordflow">if</span>(!bIs2Dim &amp;&amp; !bOnlyDimFound) {
      <span class="keywordflow">if</span> (!bOnlyDimFound &amp;&amp; pOnlyDim != NULL) {
        out &lt;&lt; <span class="stringliteral">&quot;map contains no &quot;</span> &lt;&lt; pOnlyDim-&gt;<a class="code" href="a00085.html#a722a82180c4e8ea5bf2a4a34898a841d" title="Returns the name of this dimension.">getName</a>() &lt;&lt; <span class="stringliteral">&quot; dimension!&quot;</span> &lt;&lt; endl;
      }
      <span class="keywordflow">else</span>
        out &lt;&lt; <span class="stringliteral">&quot;domain - min=&quot;</span> &lt;&lt; min &lt;&lt; <span class="stringliteral">&quot; max=&quot;</span> &lt;&lt; max &lt;&lt; endl;
      <span class="keywordflow">return</span> out;
    }
    <span class="keywordflow">if</span> (bOnlyDimFound &amp;&amp; otherPositions.empty()) {
      out &lt;&lt; <span class="stringliteral">&quot;Defines no own key entries for &quot;</span> &lt;&lt; pOnlyDim-&gt;<a class="code" href="a00085.html#a722a82180c4e8ea5bf2a4a34898a841d" title="Returns the name of this dimension.">getName</a>() &lt;&lt; <span class="stringliteral">&quot; dimension! That does NOT mean it doesn&#39;t define any attenuation.&quot;</span> &lt;&lt; endl;
      <span class="keywordflow">return</span> out;
    }

    t_time_container_type::const_iterator       tIt;
    <span class="keyword">const</span> t_time_container_type::const_iterator tItEnd = timePositions.end();
    std::stringstream                           osBorder(std::stringstream::out);
    std::stringstream                           osHeader(std::stringstream::out);
    <a class="code" href="a00150.html">mixim::math::mW2dBm&lt;argument_value_t&gt;</a>       fctor2dBm;

    <span class="keywordflow">for</span>(tIt = timePositions.begin(); tIt != tItEnd; ++tIt) {
      osHeader &lt;&lt; m.toString(*tIt * 1000, iMaxHeaderItemLen) &lt;&lt; osHeader.fill();
    }
    osBorder.fill(<span class="charliteral">&#39;-&#39;</span>);
    osBorder &lt;&lt; std::setw(iMaxLeftItemLen) &lt;&lt; <span class="stringliteral">&quot;&quot;</span> &lt;&lt; osBorder.fill() &lt;&lt; <span class="stringliteral">&quot;+&quot;</span> &lt;&lt; osBorder.fill() &lt;&lt; std::setw(osHeader.str().length()) &lt;&lt; <span class="stringliteral">&quot;&quot;</span>;

    out &lt;&lt; osBorder.str() &lt;&lt; std::endl;
    out &lt;&lt; std::setw(iMaxLeftItemLen) &lt;&lt; std::left &lt;&lt; sTableHead &lt;&lt; out.fill() &lt;&lt; <span class="stringliteral">&quot;|&quot;</span> &lt;&lt; out.fill();
    out &lt;&lt; osHeader.str() &lt;&lt; std::endl;
    out &lt;&lt; osBorder.str() &lt;&lt; std::endl;

    it = m.<a class="code" href="a00058.html#a5ff3a15fe6d536fa7a26a3fe1ff1b274" title="Returns a pointer of a new Iterator which is able to iterate over this Mapping.">createConstIterator</a>();

    <span class="keywordflow">if</span>(dims.<a class="code" href="a00086.html#a0bf532a8e4cbf151337d24b7246790a9" title="Returns the size of the DimensionSet.">size</a>() == 1) {
      out &lt;&lt; std::setw(iMaxLeftItemLen) &lt;&lt; <span class="stringliteral">&quot;value&quot;</span> &lt;&lt; out.fill() &lt;&lt; <span class="stringliteral">&quot;|&quot;</span> &lt;&lt; out.fill();
      <span class="keywordflow">while</span>(it-&gt;<a class="code" href="a00059.html#a4a6348a453418da95978e570fec046fc" title="Returns true if the current position of the iterator is in range of the function.">inRange</a>()) {
        out &lt;&lt; m.toString(fctor2dBm(it-&gt;<a class="code" href="a00059.html#ad4419c259e747867f003d07d62d4259f" title="Returns the value of the Mapping at the current position.">getValue</a>()), iMaxHeaderItemLen) &lt;&lt; out.fill();
        <span class="keywordflow">if</span>(!it-&gt;<a class="code" href="a00059.html#ad4bac7233c154b7086c6124d2e21be49" title="Returns true if the iterator has a next value it can iterate to on a call to &quot;next()&quot;.">hasNext</a>()) {
          <span class="keywordflow">break</span>;
        }
        it-&gt;<a class="code" href="a00059.html#afdafa6870cd19b3d35674a7bc777585d" title="Iterates to the next position of the Mapping.">next</a>();
      }
    } <span class="keywordflow">else</span> {
      t_value_container_type::const_iterator fIt = otherPositions.begin();

      tIt = timePositions.begin();
      out &lt;&lt; m.toString((*fIt)*lLeftColScale, iMaxLeftItemLen) &lt;&lt; out.fill() &lt;&lt; <span class="stringliteral">&quot;|&quot;</span> &lt;&lt; out.fill();
      <span class="keywordflow">while</span>(it-&gt;<a class="code" href="a00059.html#a4a6348a453418da95978e570fec046fc" title="Returns true if the current position of the iterator is in range of the function.">inRange</a>()) {
        <span class="keywordflow">if</span>(*fIt != it-&gt;<a class="code" href="a00059.html#a047e853613d5a19ff34526d0cff8fcf9" title="Returns the current position of the iterator.">getPosition</a>().<a class="code" href="a00013.html#a137a911de0281cbb519fe13727aa0813" title="Returns the value for the specified dimension.">getArgValue</a>(otherDim)) {
          ++fIt;
          out &lt;&lt; std::endl &lt;&lt; m.toString((*fIt)*lLeftColScale, iMaxLeftItemLen) &lt;&lt; out.fill() &lt;&lt; <span class="stringliteral">&quot;|&quot;</span> &lt;&lt; out.fill();
          tIt = timePositions.begin();
          assert(*fIt == it-&gt;<a class="code" href="a00059.html#a047e853613d5a19ff34526d0cff8fcf9" title="Returns the current position of the iterator.">getPosition</a>().<a class="code" href="a00013.html#a137a911de0281cbb519fe13727aa0813" title="Returns the value for the specified dimension.">getArgValue</a>(otherDim));
        }

        <span class="keywordflow">while</span>( tIt != tItEnd &amp;&amp; *tIt &lt; it-&gt;getPosition().getTime() ) {
          <span class="comment">// blank item because the header time does not match</span>
          ++tIt;
          out &lt;&lt; std::setw(iMaxHeaderItemLen+1) &lt;&lt; <span class="stringliteral">&quot;&quot;</span>;
        }
        <span class="keywordflow">if</span> ( tIt != tItEnd ) {
          <span class="comment">// jump to next header item</span>
          ++tIt;
        }

        out &lt;&lt; m.toString(fctor2dBm(it-&gt;<a class="code" href="a00059.html#ad4419c259e747867f003d07d62d4259f" title="Returns the value of the Mapping at the current position.">getValue</a>()), iMaxHeaderItemLen) &lt;&lt; out.fill();

        <span class="keywordflow">if</span>(!it-&gt;<a class="code" href="a00059.html#ad4bac7233c154b7086c6124d2e21be49" title="Returns true if the iterator has a next value it can iterate to on a call to &quot;next()&quot;.">hasNext</a>()) {
          <span class="keywordflow">break</span>;
        }
        it-&gt;<a class="code" href="a00059.html#afdafa6870cd19b3d35674a7bc777585d" title="Iterates to the next position of the Mapping.">next</a>();
      }
    }
    out &lt;&lt; std::endl &lt;&lt; osBorder.str() &lt;&lt; std::endl;
    <span class="keywordflow">return</span> out;
  }
</pre></div>
</div>
</div>
<a class="anchor" id="a473df8fa0aa441ca1adb356b17b1f59f"></a><!-- doxytag: member="ConstMapping::swap" ref="a473df8fa0aa441ca1adb356b17b1f59f" args="(ConstMapping &amp;s)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void ConstMapping::swap </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="a00058.html">ConstMapping</a> &amp;&#160;</td>
          <td class="paramname"><em>s</em></td><td>)</td>
          <td><code> [inline]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Swaps data with another ConstMapping. </p>
<dl><dt><b>Parameters:</b></dt><dd>
  <table class="params">
    <tr><td class="paramname">s</td><td>A ConstMapping of the same element and allocator types.</td></tr>
  </table>
  </dd>
</dl>
<p>This exchanges the elements between two DimensionSet's in constant time. Note that the global std::swap() function is specialized such that std::swap(s1,s2) will feed to this function. </p>

<p>References <a class="el" href="a00058.html#a009539b72014b7bed96402a5c244fca5">dimensions</a>, and <a class="el" href="a00086.html#ac1230bce09abeef30d87519bf03b3167">DimensionSet::swap()</a>.</p>

<p>Referenced by <a class="el" href="a00189.html#afd82b76846eaeea2ac5ac06255770258">RSAMMapping::operator=()</a>, <a class="el" href="a00189.html#a61ee1608b52cd975bffe1350f468a4cb">RSAMMapping::swap()</a>, <a class="el" href="a00136.html#a4aaa0e0cce7a366dee7b5be53595a74f">Mapping::swap()</a>, and <a class="el" href="a00194.html#a77247e2c90cc1d33bcfc305e575cab2c">SimpleConstMapping::swap()</a>.</p>
<div class="fragment"><pre class="fragment">  {
    <span class="comment">//::swap(s); // swap the base class members</span>
    <span class="comment">/* Swap all D members */</span>
    <a class="code" href="a00058.html#a009539b72014b7bed96402a5c244fca5" title="The dimensions of this mappings domain.">dimensions</a>.<a class="code" href="a00086.html#ac1230bce09abeef30d87519bf03b3167" title="Swaps data with another DimensionSet.">swap</a>(s.<a class="code" href="a00058.html#a009539b72014b7bed96402a5c244fca5" title="The dimensions of this mappings domain.">dimensions</a>);
  }
</pre></div>
</div>
</div>
<hr/>The documentation for this class was generated from the following file:<ul>
<li>D:/Projects/MiXiM/extsrc/mixim/src/base/phyLayer/<a class="el" href="a00298_source.html">MappingBase.h</a></li>
</ul>
</div>
</div>
  <div id="nav-path" class="navpath">
    <ul>
      <li class="navelem"><a class="el" href="a00058.html">ConstMapping</a>      </li>

    <li class="footer">Generated on Tue Mar 5 2013 21:26:31 for MiXiM by
    <a href="http://www.doxygen.org/index.html">
    <img class="footer" src="doxygen.png" alt="doxygen"/></a> 1.7.5.1 </li>
   </ul>
 </div>


</body>
</html>
